﻿﻿<!DOCTYPE html>
<html>
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
    <title>全部项目</title>
    <link href="css/public.css" rel="stylesheet"/>
    <link href="css/view.css" rel="stylesheet"/>
    <link href="css/tipbox.css" rel="stylesheet" type="text/css"/>
    <!--foot-->
    <link href="css/public_1.css" rel="stylesheet" media="all"/>
    <style></style>
    <script src="js/vue2.5.17.js"></script>
    <script type="text/javascript" src="js/jquery1.7.js"></script>
    <script src="../admin/layui/layui.all.js"></script>
    <link rel="stylesheet" href="../admin/layui/css/layui.css">
    <script src="js/route.js"></script>
</head>
<body>


<div class="header_bg">
    <div class="header wap">
        <div class="logo"><a href="/index.html" title="权名众筹系统">权名众筹系统</a></div>
        <div class="nav cfff">
            <ul>
                <li class="nav_a1"><a href="/index.html">首页</a></li>
                <li class="nav_a2"><a href="/home/list.html?projectName=&page=1&limit=10&type=0">全部项目</a></li>
                <li class="nav_a4"><a href="/home/apply.html">发布项目</a></li>                 <li class="nav_a5"><a href="/admin/index.html#/user/login">后台管理</a></li>



            </ul>
        </div>
        <div class="h_right" id="h_right_userInfo">
            <ul class="h_login h_user displayNone"
                v-bind:class="[userInfo.code===101 ? 'displayInlineBlock':'displayNone']" id="login_panel">
                <span>
                            <li class="hl_login"><a href="/home/login.html" class="h_login_ring">登录</a></li>
                            <li class="hl_reg"><a href="/home/sign.html" class="h_login_join">注册</a></li>
                            <li class="qq_login"><a href="#" title="QQ登陆">QQ登录</a></li>
                </span>
                <li class="help_login"><a href="#">帮助</a></li>
            </ul>
            <ul class="h_login  h_reg displayNone"
                v-bind:class="[userInfo.code===0 ? 'displayInlineBlock':'displayNone']" id="login_info">
                <div>
                    <li class="h_name"><a href="/home/user/user.html">{{userInfo.data!=null
                        ?userInfo.data.username:''}}</a>
                        <div class="popup name_popup cfff displayNone">
                            <a href="/home/user/user.html">我的帐户</a>
                            <a href="/home/logout">安全退出</a>
                        </div>
                    </li>
<!--<li class="h_message"><a href="#" id="notify">提醒</a>-->                         <!--<div class="popup message_popup cfff displayNone">-->                             <!--<a href="#" id="unread">未读通知 </a>-->                             <!--<a href="#" id="unreview">待评价项目 </a>-->                             <!--<a href="#" id="uncash">未兑现项目 </a>-->                         <!--</div>-->                     <!--</li>-->

                    <li class="help_login"><a href="#">帮助</a></li>
                </div>
            </ul>
        </div>
        <div class="top_nav_ti" style="display: none;" id="tips_help">
            <span class="arrow"></span>
            <p>初来乍到？先看看帮助吧！</p>
            <a href="#" class="view_btn" id="close_help">知道啦</a>
        </div>
    </div>
</div>


<div class="content wap index_contnet">
    <div class="bread_crumbs"><a href="../index.html">首页</a>&nbsp;&gt;&nbsp;<a href="#" id="href-type"></a></div>
    <div class="main">
        <div class="zc_list" id="zc_list">

            <dl v-for="d in data">
                <dt>
                    <a :href="'/home/project.html?id='+d.projectId" v-bind:title="d.name">
                        <div style="display: inline-block; width: 185px;height: 240px ; background: rgb(247, 247, 247);overflow: hidden;">
                            <img :src="d.banner"  :alt="d.name" style="height: 100%">
                        </div>
                    </a>
                    <div class="list_state">
                        <span v-if="d.projectStatus.statusId===1" class="list_state_zc">众筹中</span>
                        <span v-if="d.projectStatus.statusId===2" class="list_state_end">已结束</span>
                        <!--<span v-if="d.day===0" class="list_state_zc">已结束</span>-->
                    </div>
                </dt>
                <dd class="list_view bk">
                    <div class="list_tit">
                        <h2><a :href="'/home/project.html?id='+d.projectId" v-text="d.name">项目名称</a></h2>
                        <p class="list_author" v-text="d.homeUser.username">作者 </p>
                    </div>
                    <div class="list_intro">
                        <em>目标数：</em>￥<span v-text="d.money">0</span><br>
                        <em>当前数：</em>￥<span v-text="d.currentAllMoney">0</span><br>
                        <em>剩余时间：</em><span v-text="d.day"></span>天<br>
                    </div>
                    <div class="list_buy_btn"><a :href="'/home/project.html?id='+d.projectId">项目详情&gt;&gt;</a></div>
                </dd>
            </dl>
            <div id="page"></div>
        </div>
    </div>
    <div class="right">
        <div class="origin">
            <!--            <dl>
                            <dt></dt>
                            <dd class="cfff">
                                <span>全部项目<br><br></span>
                            </dd>
                        </dl>-->
            <form class="layui-form" action="" lay-filter="example">
                <div>

                    <div class="layui-form-item" >

                        <div style="display: inline-block">
                            <input type="text" id="projectName"   name="projectName" lay-verify="title" autocomplete="off"
                                   placeholder="请输入项目名称" class="layui-input">
                            <input type="hidden" name="page" class="layui-input" value="1">
                            <input type="hidden" name="limit" class="layui-input" value="10">
                            <input type="hidden" id="p-type" name="type" class="layui-input">
                        </div>
                        <script>
                            $("#p-type").val(GetQueryString('type')==null?0:GetQueryString('type'));

                        </script>

                        <button  class="layui-btn" style="margin-left: 10px">搜索</button>

                    </div>

                </div>
                <div id="projectType">
                    <span onclick="hrefTo(1,10,'',0)" class="layui-btn layui-btn-sm layui-btn-warm" style="margin: 5px">全部</span>
                </div>
            </form>
        </div>
    </div>
</div>


<div class="footer">
    <div class="ft_link_bg">
        <div class="ft_link">
            <dl class="ft_about">
                <a href="http://www.baidu.com" target="_blank" title="权名众筹基地">
                    <dt>众筹</dt>
                </a>
                <dd>

                </dd>
            </dl>
            <dl class="ft_coop">
                <dt>合作伙伴</dt>
                <dd>


                </dd>
            </dl>
            <dl class="ft_help">
                <dt>帮助拓展</dt>
                <dd>

                </dd>
            </dl>
        </div>
    </div>
</div>

<div class="ws_global_footer">
    <div class="ws_footer_info" style="min-width: 1000px">
        <div class="content">
            <p>
                <a href="#" target="_blank">桂ICP备123456789</a>　
                权名众筹　
                权名众筹　
                权名众筹　
                <a href="#"
                   target="_blank"
                   style="width:16px;height:16px;display:inline-block;background:url('images/wen_icon.png')">&nbsp;</a>
            </p>
            <p>
                Copyright (C) 2018 权名众筹 Rights Reserved　
                　
                　
                <a href="#" target="_blank">百度</a>
            </p>
        </div>
    </div>
</div>


<script>
    //获取头部
    $.ajax({
        url: "/home/getCurrentUser",
        async: true,
        success: function (data) {
            /*            if (data.code==101){
                            alert("请先登录");
                            window.location.href="/home/login.html";
                        }*/
            new Vue({
                el: '#h_right_userInfo',
                data: {userInfo: data}
            })
            console.log(data)
        }
    });


    //    获当项的具体信息

    // alert();

    /*    $.ajax({
            url: "/home/getProjectById",
            async: true,
            data: {'id': GetQueryString("id")},
            success: function (data) {
                new Vue({
                    el: '.content',
                    data: {projectInfo: data}
                })
                console.log(data)
            }
        });*/

</script>


<script src="handleJs/list.js"></script>
</body>
</html>
